/* Copyright (c) 2004-2024 Peigen.info. All rights reserved. */

package info.peigen.hotpot.component.data.repository.tdengine.config;

import com.zaxxer.hikari.HikariDataSource;
import org.noear.solon.annotation.Bean;
import org.noear.solon.annotation.Configuration;
import org.noear.solon.annotation.Import;
import org.noear.solon.annotation.Inject;

import javax.sql.DataSource;

/**
 * <b>(TdEngineAutoConfiguration)</b>
 *
 * @author Peigen
 * @version 1.0.0
 * @since 2022/8/1
 */
@SuppressWarnings("unused")
@Configuration
@Import(scanPackages = {"info.peigen.hotpot.component.data.repository.tdengine"})
public class TdEngineAutoConfiguration {
    @Bean(name = "tdengineDataSource", typed = true)
    public DataSource tdengineDataSource(@Inject("${hotpot.tdengineDataSource}") HikariDataSource ds) {
        return ds;
    }
}